/**
 * Copyright (c) Chris Myers 2007
 * Nov 12, 2007
 */
package com.chrisandjo.rostra.dao.jpa;

import com.chrisandjo.rostra.dao.TaskDao;
import com.chrisandjo.rostra.domain.Task;
import com.chrisandjo.rostra.domain.TaskEntity;
import org.springframework.orm.jpa.support.JpaDaoSupport;

/**
 * @author Chris
 */
public final class TaskDaoImpl extends JpaDaoSupport implements TaskDao {

    public void save(Task task) {
        getJpaTemplate().persist(task);
    }

    public Task loadById(long id) {
        return getJpaTemplate().find(TaskEntity.class, id);
    }

}
